
#include "Receiver.h"
#include "Command.h"
#include "CommandImpl.h"
#include "Invoker.h"
#include <memory>

using namespace npCommand;
using namespace std;


void doCommand()
{
    unique_ptr<Receiver> receiver(new Receiver());
    unique_ptr<Command> command(new CommandImpl());
    command->setReceiver(receiver.get());
    unique_ptr<Invoker> invoker(new Invoker());
    invoker->setCommand(command.get());
    invoker->executeCommand();
}